﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace WeatherPrediction
{
    /// <summary>
    /// Interaction logic for UserControlWeatherDay.xaml
    /// </summary>
    public partial class UserControlWeatherDay : UserControl
    {
        public UserControlWeatherDay(string title, string icon, string text, string textMetric, string pop, string imgUrl)
        {
            InitializeComponent();
            InitUserControl(title, icon, text, textMetric, pop, imgUrl);
        }

        public void InitUserControl(string title, string icon, string text, string textMetric, string pop, string imgUrl)
        {
            lbTitle.Content = title;
            lbIcon.Content = icon;
            lbText.Text = text;
            lbMetric.Text = textMetric;
            lbPop.Content = pop;
            ImageRequest.GetImage(imgUrl, imgIcon);
        }
    }
}
